package com.baijiaxing.weixin.family.message.enums;

import java.util.HashMap;
import java.util.Map;

/**
 * 消息类型
 * @author June
 *
 */
public enum FamilyMessageTypeEnum {
	TEXT("text","文本消息"),
	IMAGE("image","图片消息"),
	VOICE("voice","语音消息"),
	VIDEO("video","视频消息"),
	SHORTVIDEO("shortvideo","小视频消息"),
	LOCATION("location","地理位置消息"),
	LINK("link","链接消息"),
	MUSIC("music","音乐消息"),
	NEWS("news","图文消息"),
	EVENT("event","事件消息");
	
	private String key;
	private String value;
	
	private FamilyMessageTypeEnum(String key, String value){
		this.key = key;
		this.value = value;
	}

	public String getKey() {
		return key;
	}

	public String getValue() {
		return value;
	}

	public static Map<String,String> getMap(){
		Map<String,String> map = new HashMap<String, String>();
		for (FamilyMessageTypeEnum messageTypeEnum: FamilyMessageTypeEnum.values()) {
			map.put(messageTypeEnum.getKey(),messageTypeEnum.getValue());
		}
		return map;
	}
}
